14:56
2026-06-18
bal-e.org
developer-tools
offset_of! slices
A Rust developer created a macro to compute the compile-time offset of slice fields in structs, bypassing the limitation of std::mem::offset_of! on stable Rust. The hack uses a fake instance in a largβ¦